
class Vector{
    
//    var datas = [Int](count:100,repeatedValue:0)
    
    var datas = [Int](repeating: 0, count: 100)
    
    
    
    subscript(index:Int)-> Int{
        get{
            
            return datas[index]
        }
        set{
            print(newValue,"看看看")
            datas[index]=newValue
            
            print(datas[index],"wuwuwu")
        }
    }
}

var datas=Vector()
for i in 0..<10{
   datas[i]=i
    
    print(i,"hhh",datas[i])
}

for i in 0..<10{
    print(datas[i])
}



